home *** CD-ROM | disk | FTP | other *** search
/ Amiga Collections: Franz PD / Franz PD Disk #279 (1993)(Rhein-Sieg-Soft).zip / Franz PD Disk #279 (1993)(Rhein-Sieg-Soft).adf / ak_gen0-lib_V38.20.LHA / ak_gen0-library / Programmers.LHA / Programmers / Examples / ModeReqMode.c < prev    next >
C/C++ Source or Header  |  1993-07-11  |  1KB  |  46 lines

  1.  
  2.  /* ModeReqMode V38.1                            */
  3.  /* FREEWARE.                               */
  4.  /* (c) 1993 by Andreas R. Kleinert.                           */
  5.  /* Demonstrates how to switch the Library between :           */
  6.  /*  - "reset mode"       (default settings, usual overscan).  */
  7.  /*  - "bigoverscan mode" (special settings, big overscan).    */
  8.  /* Written in SAS/C V6.00 for OS V2.04 (V37) Includes.        */
  9.  
  10.  
  11. #include <ak_gen0/ak_gen0_base.h>
  12. #include <ak_gen0/ak_gen0_pragma.h>
  13.  
  14. #include <stdlib.h>
  15. #include <string.h>
  16.  
  17. #include <proto/exec.h>
  18. #include <proto/intuition.h>
  19.  
  20. void main(long argc, char **argv) /* MAIN */
  21. {
  22.  IntuitionBase = (struct IntuitionBase *) OpenLibrary("intuition.library", 0);
  23.  
  24.   /* will always be open because of version==0 */
  25.  
  26.  printf("\nModeReqMode V38.1, FREEWARE, (c) 1993 by Andreas R. Kleinert.\n");
  27.  
  28.  AKBase = (struct AKBase *) OpenLibrary("ak_gen0.library", 37);
  29.  if(AKBase)
  30.   {
  31.    if(!stricmp(argv[1], "RESET"))       AKBase->ak_ModeReqFlags ^= AKBM_BIGOVERSCAN;
  32.    if(!stricmp(argv[1], "BIGOVERSCAN")) AKBase->ak_ModeReqFlags |= AKBM_BIGOVERSCAN;
  33.  
  34.    CloseLibrary((APTR) AKBase);
  35.   }else
  36.   {
  37.    printf("\n Can't open \42ak_gen0.library\42 V37+ !\n");
  38.   }
  39.  
  40.  CloseLibrary((APTR) IntuitionBase);
  41.  
  42.  exit(0);
  43. }
  44.  
  45.  
  46.